<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:p="http://primefaces.prime.com.tr/ui"
	xmlns:sec="http://www.springframework.org/security/taglibs/facelets/tags">
<h:head>
	<title>JSF Demo</title>
	<style type="text/css">
		.ui-widget {
		font-size: 12px !important;
		}
	</style>
</h:head>
<h:body>

	<p:menubar autoSubmenuDisplay="true">
		<p:submenu label="File" icon="ui-icon ui-icon-document">
			<p:submenu label="New" icon="ui-icon ui-icon-contact">
				<p:menuitem value="Project" url="#" helpText="CTRL+N" />
				<p:menuitem value="Other" url="#" helpText="CTRL+O" />
			</p:submenu>
			<p:menuitem value="Open" url="#" />
			<p:menuitem value="Quit" url="#" />
		</p:submenu>

		<p:submenu label="Edit" icon="ui-icon ui-icon-pencil">
			<p:menuitem value="Undo" url="#"
				icon="ui-icon ui-icon-arrowreturnthick-1-w" helpText="CTRL+Z"></p:menuitem>
			<p:menuitem value="Redo" url="#"
				icon="ui-icon ui-icon-arrowreturnthick-1-e" helpText="CTRL+Y"></p:menuitem>
		</p:submenu>

		<p:submenu label="Help" icon="ui-icon ui-icon-help">
			<p:menuitem value="Contents" url="#" />
			<p:submenu label="Search" icon="ui-icon ui-icon-search">
				<p:submenu label="Text">
					<p:menuitem value="Workspace" url="#" />
				</p:submenu>
				<p:menuitem value="File" url="#" />
			</p:submenu>
		</p:submenu>

		<p:menuitem value="Quit" url="http://www.primefaces.org"
			icon="ui-icon ui-icon-close" />
	</p:menubar>

	<h:outputScript name="jsf.js" library="javax.faces" target="body">
	</h:outputScript>
	<h1>Ajax JSF 2 Demo - #{testeMBean.nome}</h1>
	<p:accordionPanel>
		<p:tab title="Título da Primeira Aba">
			<h:outputText value="Lorem" />
		</p:tab>
		<p:tab title="Título da Segunda Aba">
			<h:form>
				<h:inputText id="string" value="#{testeMBean.string}">
					<f:ajax render="reverseString" />
				</h:inputText>

				<h:commandButton value="Inverter!">
					<f:ajax execute="string" render="reverseString" />
				</h:commandButton>
				<h:outputText id="reverseString" value="#{testeMBean.reverseString}" />

			</h:form>
		</p:tab>
	</p:accordionPanel>

</h:body>
</html>